/*
 * @Author: weisheng
 * @Date: 2023-04-17 12:51:22
 * @LastEditTime: 2023-04-20 15:01:53
 * @LastEditors: weisheng
 * @Description:
 * @FilePath: \uniapp-vue3-fant-ts\src\api\DemoApi.ts
 * 记得注释
 */
import http from '@/http/HttpClient'
import BaseResponse from '@/model/BaseResponse'
import Chanel from '@/model/Chanel'
import UserInfo from '@/model/UserInfo'
// 这里将API方法统一管理
export default class AddMerApi {
	static getGoodsType(data) : Promise<BaseResponse<Chanel[]>> {
		return http
			.server()
			.get(`/cityAdmin/mall/goods/v2/type${data}`, {})
			.then((res) => {
				return res.data
			})
	}
	static getClassAParam(data) : Promise<BaseResponse<Chanel[]>> {
		return http
			.server()
			.get(`/cityAdmin/mall/shop_type/v2/get_param${data}`, {})
			.then((res) => {
				return res.data
			})
	}
	static getChildCatetory(data) : Promise<BaseResponse<Chanel[]>> {
		return http
			.server()
			.get(`/cityAdmin/mall/goods/child_catetory${data}`, {})
			.then((res) => {
				return res.data
			})
	}

	static getParamList(data) : Promise<BaseResponse<Chanel[]>> {
		return http
			.server()
			.get(`/cityAdmin/mall/shop_type/v2/get_param_list${data}`, {})
			.then((res) => {
				return res.data
			})
	}
	static queryAddInfo(data) : Promise<BaseResponse<Chanel[]>> {
		return http  
			.server()
			.get(`/cityAdmin/mall/shop/goodsComm/list_data${data}`, {})
			.then((res) => {
				return res.data
			})
	}
	static getDataGoodsId(data) : Promise<BaseResponse<Chanel[]>> {
		return http
			.server()
			.get(`/cityAdmin/mall/goods/get_data_by_goods_id${data}`, {})
			.then((res) => {
				return res.data
			})
	}

	//获取取车换车和技师接口
	static getLeaseData(data) : Promise<BaseResponse<Chanel[]>> {
		return http
			.server()
			.get(`/cityAdmin/mall/goods/v2/goods_type${data}`, {})
			.then((res) => {
				return res.data
			})
	}

	static trashPublish(data) : Promise<BaseResponse<Chanel[]>> {
		return http
			.server()
			.post('/cityAdmin/mall/goods/v2/trash_publish', data, {})
			.then((res) => {
				return res.data
			})
	}
}